import { connect } from 'dva';
import React, { useEffect, useState } from 'react';
import styles from './index.less';


const detail = props => {
  const { form, dispatch } = props;
  const [status, setStatus] = useState(false)

  const [detail, setDetail] = useState({
    title: "企业IT规划发展的三个时期",
    time: "2022-1-21",
    author: "作者",
    content: "IT规划不是摆设，它必须在得到切实可行的实施之后，IT规划不是摆设，它必须在得到切实可行的实施之后，IT规划不是摆设，它必须在得到切实可行的实施之后，IT规划不是摆设，它必须在得到切实可行的实施之后，才能发挥出促进业务、提",
  })
  useEffect(() => {
    // localStorage.setItem('deptId',props?.location?.query?.deptId || '')
    // dispatch({
    //   type:'Evaluation/checkDemocracyEvaluationTime',
    //   payload:{}
    // }).then((res)=>{
    //   setStatus(res)
    // })
  }, [])

  return (
    <div className={styles.detail}>
      <div className={styles.detailVal}>
        <h3 >{detail.title}</h3>
        <div className={styles.timeAuthor}>
          <div className={styles.time}>时间: {detail.time}</div>
          <div className={styles.author}>作者: {detail.author}</div>
        </div>
        <div className={styles.content}
          dangerouslySetInnerHTML={{ __html: detail.content }}>
        </div>
      </div>
    </div>
  );
};

export default connect(({ }) => ({}))(detail);
